package logic;

import ui.ScreenWB;
import db.BankDatabase;
//import db.AtmDatabase;

// BalanceInquiry.java
// Represents a balance inquiry ATM transaction

public class BalanceInquiry extends Transaction {
	// BalanceInquiry constructor
	public BalanceInquiry(int userAccountNumber, ScreenWB atmScreen,
			BankDatabase atmBankDatabase) {
		super(userAccountNumber, atmScreen, atmBankDatabase);

	} // end BalanceInquiry constructor

	String[] columnNames = { "Accountnumber", "Balance" };

	Object[][] data = { { new Integer(10000), new Double(12334.1) },
			{ new Integer(10001), new Double(100000.12) } };
	
	// performs the transaction
	public void execute() {

		// get references to bank database and screen
		Screen screen = getScreen();

		// get the available balance for the spending-account involved
		double availableSpendingBalance = bankDatabase
				.getAvailableSpendingBalance(getAccountNumber());

		// get the total balance for the spending-account involved
		double totalSpendingBalance = bankDatabase
				.getTotalSpendingBalance(getAccountNumber());

		// get the total balance for the savings-account involved
		double totalSavingsBalance = bankDatabase
				.getTotalSavingsBalance(getAccountNumber());

		// get the available balance for the spending-account involved
		double availableBudgetBalance = bankDatabase
				.getAvailableBudgetBalance(getAccountNumber());

		// get the total balance for the spending-account involved
		double totalBudgetBalance = bankDatabase
				.getTotalBudgetBalance(getAccountNumber());

	} // end method execute
	
} // end class BalanceInquiry

